import React from "react";
import { BrowserRouter, Routes, Route } from "react-router-dom";
import Home from "../components/home";
import Login from "../components/login";
import List from "../components/list";
import MainLayout from "../components/mainLayout";

const Index: React.FC = () => {
  return (
    <BrowserRouter>
      <Routes>
        <Route path="/login" element={<Login></Login>}></Route>
        <Route path="/" element={<MainLayout></MainLayout>}>
          <Route path="home" element={<Home></Home>}></Route>
          <Route path="list" element={<List></List>}></Route>
        </Route>
      </Routes>
    </BrowserRouter>
  );
};

export default Index;
